<?php session_start(); 
if($_SESSION['ID']!= null){
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title><?php echo $ID=$_SESSION['ID']; ?>你好!</title>
<link href="css/pannel.css" type="text/css" rel="stylesheet">
<link href="css/reset.css" type="text/css" rel="stylesheet">
<script type="text/javascript" language="javascript">
function changeIFR(url)
{
document.getElementById('main-ifr').src = url + '.php';
}
</script>
</head>

<body>
<iframe src="upper-pannel.html" scrolling="no" frameborder="0" id="upper-pannel" style="height:37px; width:100%;"></iframe>
<div id="pannel-outer-wrapper">
<div id="pannel-wrapper">
<div id="pannel-wrapper-header">

<span id="pannel-wrapper-welcome">Hello, <?php echo $ID=$_SESSION['ID']; ?>! Wellcome to Trackary.</span>


<ol id="pannel-wrapper-chosen">
<li><a href="#" onclick="changeIFR('proj_list')">Your Track</a></li>
<li><a href="#" onclick="changeIFR('proj_add')">Add Track</a></li>
<li><a href="#" onclick="changeIFR('user_edit')">Profile</a></li>
</ol>


</div>


<iframe id="main-ifr" scrolling="no" frameborder="0"  src="proj_list.php"></iframe>

</div>
</div>
</body>
</html>













<!--
/*
<?php
   $ID=$_SESSION['ID'];
   $UserNo=$_SESSION['UserNo']; 
?>
<?php

require('config.inc.php');
require('db.php');

db_connect();

db_select();
?>
<?php


$sql = '';
$sql .= 'SELECT * FROM project WHERE UserNo=\''.$UserNo.'\'';

$result = mysql_query($sql) or die('Invalid query: ' . mysql_error());



?>

<span class="style1">Hello!</span>
<?php
   echo $ID;

?>
</p>
<p class="style2">編輯你的檔案:</p>
<p>
<?php 
while ($row = mysql_fetch_assoc($result)) {
    echo  "<a target='blank' href = 'index1.php?No=".$row['fname'] ."'>".$row['pname'] . '</a>' . '<br>';
}
echo '</p>';
mysql_free_result($result);
?>
</p>
<p><a href="file_upload.php" class="style2">Create a new project</a></p>


<?php
   db_close();
}else{
   header("Location:"."login.html");
}
?>
*/
-->